package dk.marten.ibdrecord;

import android.os.Bundle;
import android.app.ActionBar;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.Toast;

public class MainActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		
//		ActionBar actionBar = getActionBar();
//        actionBar.setDisplayShowTitleEnabled(true);
//        actionBar.setDisplayShowHomeEnabled(false);
//        actionBar.setDisplayShowCustomEnabled(true);
        
        
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.activity_main, menu);
		return true;
	}
	
	public boolean onOptionsItemSelected(MenuItem item) {
		switch(item.getItemId()){
		case R.id.about_btn:
			Intent intent = new Intent(this, About.class);
			 startActivity(intent);
			break;		
		}
        return true;
    }	 
	
	 public void gotoRedigerToilet(View view) {
		 Intent intent = new Intent(this, RedigerToilet.class);
		 startActivity(intent);
	 }
	
	 public void gotoRedigerTilstand(View view) {
		 Intent intent = new Intent(this, RedigerTilstand.class);
		 startActivity(intent);
	 }
	
	 public void gotoHistory(View view) {
		 Intent intent = new Intent(this, History.class);
		 startActivity(intent);
	 }
	
	 public void gotoExport(View view) {
		 Intent intent = new Intent(this, ExportData.class);
		 startActivity(intent);
	 }
	
	 public void gotoOversigt(View view) {
		 Intent intent = new Intent(this, Oversigt.class);
		 startActivity(intent);
	 }
	 
	 
	 

}
